﻿{% extends "blog/base.html" %}
{% block page-content%}
{% block job %}
  <h1 align="center">工作兼职版块</h1>
  <hr style="height:1px;border:none;border-top:1px dashed #0066CC;" /> 
   <ul class="nav nav-pills navbar-right" role="tablist">
         <li role="presentation" class="active">
              <a href="/job/bbs_pub">发帖</a>
         </li>
     </ul>
     
  {% if tag %}
    <h2>Posts tagged with "{{ tag.name }}"</h2>
    
  {% endif %}

  {% for job in jobs %}
    <h2>
      <a href="{{ job.get_absolute_url }}">
        {{ job.title }}
      </a>
    </h2>
    
<!-- 显示tags的内容   -->
    <p class="tags">
  标签:
  {% for tag in job.tags.all %}
    <a href="{% url "job:job_list_by_tag" tag.slug %}">
      {{ tag.name }}
    </a>
    {% if not forloop.last %}, {% endif %}
  {% endfor %}
</p>

    <p class="date">
      Published {{ job.publish }} by {{ job.author }}
    </p>
    {{ job.body|truncatewords:30|linebreaks }}
  {% endfor %}
 
  {% include "pagination.html" with page=jobs %}

{% endblock %}
{% endblock %}